<?php 

/**
 * Joomla! 1.5 component arts_curriculum
 * @package com_arts_curriculum
 **/

// no direct access
defined( '_JEXEC' ) or die( 'Restricted access' );


  /**
  * @package arts_curriculum
  */
	  class Arts_curriculumHelper {
	
		function checkCategories() {
	  	
	  	global $mainframe ;
	  	
	  	$db =& JFactory::getDBO();
	  	$db->setQuery( "SELECT * FROM #__categories WHERE `section`='com_arts_curriculum'" ) ;
	  	$rows = $db->loadAssocList() ;
	  	if(empty($rows)) {
	 	$mainframe->enqueueMessage( JText::_( 'You have no categories configured yet' ), 'notice' ) ;
	  	return false ;
	  	}
	  	return true ;
	  
	  }
	 
		function checkCategories2() {
	  	
	  	global $mainframe ;
	  	
	  	$db =& JFactory::getDBO();
	  	$db->setQuery( "SELECT * FROM #__categories WHERE `section`='com_arts_curriculum'" ) ;
	  	$rows = $db->loadAssocList() ;
	  	if(empty($rows)) {
	 	$mainframe->enqueueMessage( JText::_( 'You have no vocabulary categories configured yet' ), 'notice' ) ;
	  	return false ;
	  	}
	  	
	  	return true ;
	  }



		
	

} //the end